<%@ taglib prefix="s" uri="/struts-tags" %>
<html>
	<head>
		<title><s:text name="application.title"/></title>
		<link href="<s:url value="/css/main.css"/>" rel="stylesheet"
		type="text/css"/>
	</head>
	<body>
		<div class="titleDiv"><s:text name="application.title"/></div>
		<h1>
			<s:text name="label.studentSubjectMarkingForm.addMark"/> 
		</h1>
		<br/>
		
		<table class="borderAll">
		    <tr>
		        <th><s:text name="header.subjectStudents.dni"/></th>
				<th><s:text name="header.subjectStudents.name"/></th>
				<th><s:text name="header.subjectStudents.number"/></th>
		        <th>&nbsp;&nbsp;</th>
		    </tr>
		        <tr class="<s:if test="#status.even">even</s:if><s:else>odd</s:else>">
		            <td class="nowrap"><s:property value="alu.dni"/></td>
		            <td class="nowrap"><s:property value="alu.nombre"/></td>
		            <td class="nowrap"><s:property value="alu.telefono"/></td>
		            
		    	</tr>
		</table>
		
		<table class="borderAll">
		    <tr>
		        <th><s:text name="header.lecturerSubjects.code"/></th>
		        <th><s:text name="header.lecturerSubjects.name"/></th>
		        <th><s:text name="header.lecturerSubjects.credits"/></th>
		        <th><s:text name="header.lecturerSubjects.professor"/></th>
		        <th><s:text name="header.lecturerSubjects.nStudents"/></th>
		        <th>&nbsp;&nbsp;</th>
		    </tr>
		        <tr class="<s:if test="#status.even">even</s:if><s:else>odd</s:else>">
		            <td class="nowrap"><s:property value="asig.codigo"/></td>
		            <td class="nowrap"><s:property value="asig.nombre"/></td>
		            <td class="nowrap"><s:property value="asig.creditos"/></td>
		            <td class="nowrap"><s:property value="%{asig.prof.getNombre()}"/></td>
		            <td class="nowrap"><s:property value="%{asig.alumnos.size()}"/></td>
		    	</tr>
		</table>
		
		<s:form action="doSubjectMarking!saveMark" method="POST">
			<s:hidden
				name="asigID" value="%{asigID}"
			/>
			<s:hidden
				name="aluDNI" value="%{aluDNI}"
			/>
			
			<s:textfield
				name="concept" 
				label="%{getText('label.studentSubjectMarkingForm.concept')}"
			/>
			<s:textfield
				name="mark" 
				label="%{getText('label.studentSubjectMarkingForm.mark')}"
			/>
			
			<s:submit
				value="%{getText('label.login.button')}" 
				align="center"
			/>
		</s:form>
		
		<s:form action="doLecturer" method="POST">
			<s:submit
				value="%{getText('label.subjectStudents.button')}"
				align="center"
			/>
		</s:form>
	</body>

</html>